#[derive(serde::Deserialize, serde::Serialize, Debug, Default, Clone)]
pub struct Auth {
    pub username: String,
    pub password: String,
}
impl Auth {
    pub fn new() -> Self {
        Self::default()
    }
    pub fn serialize(&self) -> Result<String, serde_json::Error> {
        serde_json::to_string(&self)
    }
    pub fn deserialize(value: &[u8]) -> Result<Self, serde_json::Error> {
        serde_json::from_slice::<Self>(value)
    }
}
